<template>
  <div class="container">
    <div class="content">
      <div class="title">
        我的作品
      </div>
      <div class="tags">
        <div class="label">所属标签：</div>
        <div class="tag">全部</div>
        <div
          :class="['tag',{ active: i == 5 }]"
          v-for="i in 10"
          :key="i"
        >类目{{i}}</div>
      </div>
      <div class="list">
        <div
          class="item"
          v-for="i in 7"
          :key="i"
        >
          <div class="img">
            <img
              :src="i==2?img2:img1"
              alt=""
            >
          </div>
          <div class="name">
            蓝色格纹休闲套装服装设计效果图蓝色格纹休闲套装服装设计效果图蓝色格纹休
          </div>
          <div class="info">
            <div class="text">￥1256</div>
            <div class="time">
              库存
              <span>25</span> / 355
            </div>
          </div>
          <div class="label">
            <span>国风</span>
            <span>女</span>
            <span>套装</span>
          </div>
        </div>
      </div>
      <div class="page">
        <el-pagination
          background
          layout="total, prev, pager, next"
          :total="1000"
        >
        </el-pagination>
      </div>
    </div>
  </div>
</template>

<script>
import img1 from '@/assets/1.jpg';
import img2 from '@/assets/2.png';
export default {
  data() {
    return {
      img1: img1,
      img2: img2
    };
  }
};
</script>

<style scoped>
.container {
  background: #f0f2f5;
  padding: 25px;
  font-size: 14px;
}
.container .content {
  background: #ffffff;
  padding-bottom: 40px;
}
.content .title {
  padding: 20px 30px;
  font-size: 20px;
  font-weight: bold;
  border-bottom: 1px solid #eee;
  color: #000000d8;
}
.title .el-button {
  margin-left: 10px;
}
.tags {
  padding: 20px 0;
  margin: 0 20px;
  display: flex;
  align-items: center;
  color: #000000a5;
  border-bottom: 1px dashed #ccc;
}
.tags .label {
  color: #000000d8;
}
.tags .tag {
  padding: 8px 10px;
  margin-right: 4px;
}
.tag.active,
.tag:hover {
  color: #fff;
  background-color: #409eff;
  border-color: #409eff;
  border-radius: 4px;
}
.list {
  display: flex;
  flex-wrap: wrap;
  padding: 40px 40px 0;
}
.list .item {
  width: 30%;
  margin-right: 5%;
  border: 1px solid #eee;
  margin-bottom: 30px;
  padding: 10px 0;
  display: flex;
  flex-direction: column;
}
.item:hover {
  box-shadow: 1px 1px 5px #888888;
}
.item:nth-child(3n) {
  margin-right: 0;
}
.item .img {
  margin: 0 10px 10px;
  border: 1px solid #eee;
  border-radius: 4px;
}
.item img {
  height: 300px;
  max-width: 100%;
}
.item .info {
  padding: 10px;
  display: flex;
  justify-content: space-between;
}
.info .text {
  font-size: 14px;
  color: #7f7f7f;
}
.info .time {
  color: #aaa;
}
.time span {
  color: #d9001b;
  padding-left: 6px;
}
.item .name {
  padding: 0 10px 10px;
  color: #aaaaaa;
  font-size: 14px;
  height: 40px;
  line-height: 20px;
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}
.item .label {
  padding: 0 10px;
}
.item .label span {
  background: #facd91;
  padding: 4px 8px;
  color: #fff;
  border-radius: 4px;
  margin-right: 8px;
}
.page {
  text-align: center;
}
</style>